//  我的积分
//  IntegralViewController.m
//  GoBigMarket
//
//  Created by 李真 on 16/8/20.
//  Copyright © 2016年 legend. All rights reserved.
//

#import "IntegralViewController.h"

@interface IntegralViewController ()
@property (nonatomic,strong)NSMutableArray *dataArr;
@end

@implementation IntegralViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    self.navigationItem.title = @"我的积分";
    self.backView.layer.masksToBounds = YES;
    self.backView.layer.cornerRadius = 5;
}


//设置积分
-(void)setNum:(NSInteger)num{
    _integralLabel.text = [NSString stringWithFormat:@"%ld分",num];
}
//如果没有积分使用记录的话，就是self.tableView隐藏，把imageView显示出来

#pragma mark - UITableViewDataSource

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
    return 10;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"logCell"];
    if (!cell) {
        cell = [[UITableViewCell alloc]initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"logCell"];
    }
    cell.textLabel.text = [NSString stringWithFormat:@"%@",indexPath];
    cell.textLabel.numberOfLines = 0;
    cell.contentView.backgroundColor = GDJRandomColor;
    return cell;
}

#pragma mark - UITableViewDelegate
//点击事件
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
    //退出当前页，并携带一定的信息
//    [self.navigationController popViewControllerAnimated:YES];
}

@end
